package cn.chenhongchao.hospital.entity;

import java.util.ArrayList;
import java.util.List;

public class MedicineExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public MedicineExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andIdIsNull() {
            addCriterion("ID is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("ID is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(String value) {
            addCriterion("ID =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(String value) {
            addCriterion("ID <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(String value) {
            addCriterion("ID >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(String value) {
            addCriterion("ID >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(String value) {
            addCriterion("ID <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(String value) {
            addCriterion("ID <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLike(String value) {
            addCriterion("ID like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotLike(String value) {
            addCriterion("ID not like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<String> values) {
            addCriterion("ID in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<String> values) {
            addCriterion("ID not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(String value1, String value2) {
            addCriterion("ID between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(String value1, String value2) {
            addCriterion("ID not between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andMedicineNameIsNull() {
            addCriterion("medicine_name is null");
            return (Criteria) this;
        }

        public Criteria andMedicineNameIsNotNull() {
            addCriterion("medicine_name is not null");
            return (Criteria) this;
        }

        public Criteria andMedicineNameEqualTo(String value) {
            addCriterion("medicine_name =", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameNotEqualTo(String value) {
            addCriterion("medicine_name <>", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameGreaterThan(String value) {
            addCriterion("medicine_name >", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameGreaterThanOrEqualTo(String value) {
            addCriterion("medicine_name >=", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameLessThan(String value) {
            addCriterion("medicine_name <", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameLessThanOrEqualTo(String value) {
            addCriterion("medicine_name <=", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameLike(String value) {
            addCriterion("medicine_name like", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameNotLike(String value) {
            addCriterion("medicine_name not like", value, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameIn(List<String> values) {
            addCriterion("medicine_name in", values, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameNotIn(List<String> values) {
            addCriterion("medicine_name not in", values, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameBetween(String value1, String value2) {
            addCriterion("medicine_name between", value1, value2, "medicineName");
            return (Criteria) this;
        }

        public Criteria andMedicineNameNotBetween(String value1, String value2) {
            addCriterion("medicine_name not between", value1, value2, "medicineName");
            return (Criteria) this;
        }

        public Criteria andScaleIsNull() {
            addCriterion("scale is null");
            return (Criteria) this;
        }

        public Criteria andScaleIsNotNull() {
            addCriterion("scale is not null");
            return (Criteria) this;
        }

        public Criteria andScaleEqualTo(String value) {
            addCriterion("scale =", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleNotEqualTo(String value) {
            addCriterion("scale <>", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleGreaterThan(String value) {
            addCriterion("scale >", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleGreaterThanOrEqualTo(String value) {
            addCriterion("scale >=", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleLessThan(String value) {
            addCriterion("scale <", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleLessThanOrEqualTo(String value) {
            addCriterion("scale <=", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleLike(String value) {
            addCriterion("scale like", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleNotLike(String value) {
            addCriterion("scale not like", value, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleIn(List<String> values) {
            addCriterion("scale in", values, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleNotIn(List<String> values) {
            addCriterion("scale not in", values, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleBetween(String value1, String value2) {
            addCriterion("scale between", value1, value2, "scale");
            return (Criteria) this;
        }

        public Criteria andScaleNotBetween(String value1, String value2) {
            addCriterion("scale not between", value1, value2, "scale");
            return (Criteria) this;
        }

        public Criteria andBatchNumIsNull() {
            addCriterion("batch_num is null");
            return (Criteria) this;
        }

        public Criteria andBatchNumIsNotNull() {
            addCriterion("batch_num is not null");
            return (Criteria) this;
        }

        public Criteria andBatchNumEqualTo(String value) {
            addCriterion("batch_num =", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumNotEqualTo(String value) {
            addCriterion("batch_num <>", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumGreaterThan(String value) {
            addCriterion("batch_num >", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumGreaterThanOrEqualTo(String value) {
            addCriterion("batch_num >=", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumLessThan(String value) {
            addCriterion("batch_num <", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumLessThanOrEqualTo(String value) {
            addCriterion("batch_num <=", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumLike(String value) {
            addCriterion("batch_num like", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumNotLike(String value) {
            addCriterion("batch_num not like", value, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumIn(List<String> values) {
            addCriterion("batch_num in", values, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumNotIn(List<String> values) {
            addCriterion("batch_num not in", values, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumBetween(String value1, String value2) {
            addCriterion("batch_num between", value1, value2, "batchNum");
            return (Criteria) this;
        }

        public Criteria andBatchNumNotBetween(String value1, String value2) {
            addCriterion("batch_num not between", value1, value2, "batchNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumIsNull() {
            addCriterion("approval_num is null");
            return (Criteria) this;
        }

        public Criteria andApprovalNumIsNotNull() {
            addCriterion("approval_num is not null");
            return (Criteria) this;
        }

        public Criteria andApprovalNumEqualTo(String value) {
            addCriterion("approval_num =", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumNotEqualTo(String value) {
            addCriterion("approval_num <>", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumGreaterThan(String value) {
            addCriterion("approval_num >", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumGreaterThanOrEqualTo(String value) {
            addCriterion("approval_num >=", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumLessThan(String value) {
            addCriterion("approval_num <", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumLessThanOrEqualTo(String value) {
            addCriterion("approval_num <=", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumLike(String value) {
            addCriterion("approval_num like", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumNotLike(String value) {
            addCriterion("approval_num not like", value, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumIn(List<String> values) {
            addCriterion("approval_num in", values, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumNotIn(List<String> values) {
            addCriterion("approval_num not in", values, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumBetween(String value1, String value2) {
            addCriterion("approval_num between", value1, value2, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andApprovalNumNotBetween(String value1, String value2) {
            addCriterion("approval_num not between", value1, value2, "approvalNum");
            return (Criteria) this;
        }

        public Criteria andEffectsIsNull() {
            addCriterion("effects is null");
            return (Criteria) this;
        }

        public Criteria andEffectsIsNotNull() {
            addCriterion("effects is not null");
            return (Criteria) this;
        }

        public Criteria andEffectsEqualTo(String value) {
            addCriterion("effects =", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsNotEqualTo(String value) {
            addCriterion("effects <>", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsGreaterThan(String value) {
            addCriterion("effects >", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsGreaterThanOrEqualTo(String value) {
            addCriterion("effects >=", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsLessThan(String value) {
            addCriterion("effects <", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsLessThanOrEqualTo(String value) {
            addCriterion("effects <=", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsLike(String value) {
            addCriterion("effects like", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsNotLike(String value) {
            addCriterion("effects not like", value, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsIn(List<String> values) {
            addCriterion("effects in", values, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsNotIn(List<String> values) {
            addCriterion("effects not in", values, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsBetween(String value1, String value2) {
            addCriterion("effects between", value1, value2, "effects");
            return (Criteria) this;
        }

        public Criteria andEffectsNotBetween(String value1, String value2) {
            addCriterion("effects not between", value1, value2, "effects");
            return (Criteria) this;
        }

        public Criteria andBzqIsNull() {
            addCriterion("bzq is null");
            return (Criteria) this;
        }

        public Criteria andBzqIsNotNull() {
            addCriterion("bzq is not null");
            return (Criteria) this;
        }

        public Criteria andBzqEqualTo(String value) {
            addCriterion("bzq =", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqNotEqualTo(String value) {
            addCriterion("bzq <>", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqGreaterThan(String value) {
            addCriterion("bzq >", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqGreaterThanOrEqualTo(String value) {
            addCriterion("bzq >=", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqLessThan(String value) {
            addCriterion("bzq <", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqLessThanOrEqualTo(String value) {
            addCriterion("bzq <=", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqLike(String value) {
            addCriterion("bzq like", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqNotLike(String value) {
            addCriterion("bzq not like", value, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqIn(List<String> values) {
            addCriterion("bzq in", values, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqNotIn(List<String> values) {
            addCriterion("bzq not in", values, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqBetween(String value1, String value2) {
            addCriterion("bzq between", value1, value2, "bzq");
            return (Criteria) this;
        }

        public Criteria andBzqNotBetween(String value1, String value2) {
            addCriterion("bzq not between", value1, value2, "bzq");
            return (Criteria) this;
        }

        public Criteria andRunitPriceIsNull() {
            addCriterion("runit_price is null");
            return (Criteria) this;
        }

        public Criteria andRunitPriceIsNotNull() {
            addCriterion("runit_price is not null");
            return (Criteria) this;
        }

        public Criteria andRunitPriceEqualTo(Float value) {
            addCriterion("runit_price =", value, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceNotEqualTo(Float value) {
            addCriterion("runit_price <>", value, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceGreaterThan(Float value) {
            addCriterion("runit_price >", value, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceGreaterThanOrEqualTo(Float value) {
            addCriterion("runit_price >=", value, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceLessThan(Float value) {
            addCriterion("runit_price <", value, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceLessThanOrEqualTo(Float value) {
            addCriterion("runit_price <=", value, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceIn(List<Float> values) {
            addCriterion("runit_price in", values, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceNotIn(List<Float> values) {
            addCriterion("runit_price not in", values, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceBetween(Float value1, Float value2) {
            addCriterion("runit_price between", value1, value2, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andRunitPriceNotBetween(Float value1, Float value2) {
            addCriterion("runit_price not between", value1, value2, "runitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceIsNull() {
            addCriterion("wunit_price is null");
            return (Criteria) this;
        }

        public Criteria andWunitPriceIsNotNull() {
            addCriterion("wunit_price is not null");
            return (Criteria) this;
        }

        public Criteria andWunitPriceEqualTo(Float value) {
            addCriterion("wunit_price =", value, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceNotEqualTo(Float value) {
            addCriterion("wunit_price <>", value, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceGreaterThan(Float value) {
            addCriterion("wunit_price >", value, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceGreaterThanOrEqualTo(Float value) {
            addCriterion("wunit_price >=", value, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceLessThan(Float value) {
            addCriterion("wunit_price <", value, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceLessThanOrEqualTo(Float value) {
            addCriterion("wunit_price <=", value, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceIn(List<Float> values) {
            addCriterion("wunit_price in", values, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceNotIn(List<Float> values) {
            addCriterion("wunit_price not in", values, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceBetween(Float value1, Float value2) {
            addCriterion("wunit_price between", value1, value2, "wunitPrice");
            return (Criteria) this;
        }

        public Criteria andWunitPriceNotBetween(Float value1, Float value2) {
            addCriterion("wunit_price not between", value1, value2, "wunitPrice");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}